Private Sub Workbook_BeforeClose(Cancel As Boolean)

    Dim ̸ As Name
    Dim  As Range
    
    Const xlRed As Integer = 3
    Const xlBlack As Integer = 1
    
    For Each ̸ In ThisWorkbook.Names
        
        If ̸.Name Like "input*" Then
    
            Set  = ̸.RefersToRange
                    
            If IsEmpty() Then
        
                .Offset(, -1).MergeArea.Font.ColorIndex = xlRed
                Cancel = True
        
            Else
            
                .Offset(, -1).MergeArea.Font.ColorIndex = xlBlack
        
            End If
    
        End If
    
    Next
    
End Sub